﻿using System;
using System.Collections.Generic;
using System.Web;
using System.Web.UI;
using System.Web.UI.WebControls;
using System.Data;
using System.Security;
using System.Xml.XPath;
using System.IO;
using System.Xml.Xsl;
using ObjectPersistence;
using KYO.DAL;
using Portal.API;
using System.Transactions;


public partial class Admin_Controls_Mod_AddinManager_AddinManagerCreate : AddinManagerBase
{
    List<Message> list = new List<Message>();
    protected void Page_Load(object sender, EventArgs e)
    {
       
    }
    protected override void OnInit(EventArgs e)
    {
        //CreateModuleOption();
        SaveTool1.SaveClick += new EventHandler(SaveTool1_SaveClick);
        SaveTool1.CancelClick += new EventHandler(SaveTool1_CancelClick);
        SaveTool1.ApplyClick += new EventHandler(SaveTool1_ApplyClick);
        base.OnInit(e);
    }

    void SaveTool1_ApplyClick(object sender, EventArgs e)
    {
       
    }

    void SaveTool1_CancelClick(object sender, EventArgs e)
    {
        
    }

    void SaveTool1_SaveClick(object sender, EventArgs e)
    {
        //Get data and Save using Transaction
       
         //Using transaction Decorator for code block

        try
        {
            ProcessModuleOptionResults(Action.CREATE);
            View(PageView.AddinManager, Action.LIST);
        }
        catch (Exception ex)
        {


            list.Add(new Message("Update Is fail!"));
            list.Add(new Message(ex.Message));
            ViewMessage(list, MessageType.Error);
        }
        
        
    }



  
  
}
